package com.aplink.generic.constant.type;

public enum ControlType {
	FLOATING_AUTOCOMPLETE("FloatingAutoComplete"),
	AUTOCOMPLETE_TEXTVIEW("AutoCompleteTextView"),
	BUTTON("Button"),
	CHECKBOX("CheckBox"),
	DATETIME_PICKER("DateTimePicker"),
	EDITTEXT("EditText"),
	FLOATTING_EDITTEXT("FloatingEditText"),
	GALLERY("Gallery"),
	GOOGLE_MAPS("GoogleMaps"),
	GRIDVIEW("GridView"),
	IMAGEVIEW("ImageView"),
	LISTVIEW("ListView"),
	RADIO_BUTTON("RadioButton"),
	SPINNER("Spinner"),
	SWITCH("Switch"),
	TABHOST("TabHost"),
	TEXTVIEW("TextView"),
	TOGGLE_BUTTON("ToggleButton"),
	VIEWPAGER("ViewPager");

	public static ControlType get(final String value) {
		for (final ControlType controlType : ControlType.values()) {
			if (controlType.mValue.equalsIgnoreCase(value)) {
				return controlType;
			}
		}
		return null;
	}

	private String mValue;

	private ControlType(final String value) {
		this.mValue = value;
	}

	public String getValue() {
		return this.mValue;
	}
}
